<meta property="qc:admins" content="25233160436270006375" />
<style>
	li{margin-right: 2px}
	ul{width:800px;}
</style>

<?php

/* @var $this yii\web\View */
use yii\helpers\Html;
use yii\helpers\ArrayHelper;
use yii\bootstrap\ActiveForm;
use yii\widgets\LinkPager;
$this->title = '高阳明天--课程';
?>
<link rel="stylesheet" type="text/css" href="/assets/css/zaixianjiaoyu.css">

<!--主体-->
<div class="main_outer">
  <div class="main">
	<?php if($type){?>
		<p class="p1">
			<a href="<?php echo \Yii::$app->urlManager->createUrl(['course/index',$keyword,array('type'=>0)]); ?>"
			<?php if($keyword['type']=='0' || empty($keyword['type'])){
							echo "class='bule'";
							} ?>
							>全部</a>
			<?php foreach($type as $k=>$v){?>

				<a href="<?php echo \Yii::$app->urlManager->createUrl(['course/index',$keyword,array('type'=>$v['type_id'])])?>"
				<?php if($keyword['type']==$v['type_id']){
							echo "class='bule'";
							} ?>>
					<?= Html::encode($v->type_name) ?>
					</a>
			<?php }?>
		</p>
	<?php }?>
	<?php if($source){?>
		<p>
			<span>来源：</span>
			<a href="<?php echo \Yii::$app->urlManager->createUrl(['course/index',$keyword,array('source'=>0)]); ?>"
			<?php if($keyword['source']=='0'|| empty($keyword['source'])){
										echo "class='bule'";
										} ?>
										>全部</a>
			<?php foreach($source as $k=>$v){?>

				<a href="<?php echo \Yii::$app->urlManager->createUrl(['course/index',$keyword,array('source'=>$v['source_id'])])?>"
				<?php if($keyword['source']==$v['source_id']){
							echo "class='bule'";
							} ?>>
				<?= Html::encode($v->source_name) ?>
				</a>
			<?php
				if(($k+1)%1 == 5){
					echo '</p><p class="p5">';
				}
			}?>
		</p>
	<?php }?>
	<?php if($source){?>
		<p>
			<span>难度：</span>
			<a href="<?php echo \Yii::$app->urlManager->createUrl(['course/index',$keyword,array('rank'=>0)]); ?>"
			<?php if($keyword['rank']=='0' || empty($keyword['rank'])){
							echo "class='bule'";
							} ?>>全部</a>
			<?php foreach($rank as $k=>$v){?>

				<a href="<?php echo \Yii::$app->urlManager->createUrl(['course/index',$keyword,array('rank'=>$v['rank_id'])])?>"
				<?php if($keyword['rank']==$v['rank_id']){
							echo "class='bule'";
							} ?>>
				<?= Html::encode($v->rank_name) ?></a>
			<?php
				if(($k+1)%1 == 7){
					echo '</p><p class="p5">';
				}
			}?>
		</p>
	<?php }?>
	<?php if($source){?>
		<p>
			<span>类别：</span>

			<a href="<?php echo \Yii::$app->urlManager->createUrl(['course/index',$keyword,array('cate'=>0)]); ?>"
			<?php if($keyword['cate']=='0' || empty($keyword['cate'])){
							echo "class='bule'";
							} ?>>全部</a>
			<?php foreach($cate as $k=>$v){?>

				<a href="<?php echo \Yii::$app->urlManager->createUrl(['course/index',$keyword,array('cate'=>$v['cate_id'])])?>"
				<?php if($keyword['cate']==$v['cate_id']){
							echo "class='bule'";
							} ?>
							><?= Html::encode($v->cate_name) ?></a>
			<?php
				if(($k+1)%1 == 4){
					echo '</p><p class="p5">';
				}
			}?>
		</p>
	<?php }?>
  </div>
</div>
<div class="main2_outer">
  <div class="main2">
   	<h3>最新课程</h3>
    <?php foreach ($course as $k => $v) { ?>
    <div class="box1"> <a href="#">
        <?php if(!empty($v['course_thumb'])) { ?>
           <img src="http://files.bwphp.com/<?php echo $v['course_thumb'] ?>" width="700" height="364" /
       <?php } ?>
       <img src="http://admin.bwphp.com/css/course/coursePicture" width="700" height="364" />
        </a>
    </div>
    <div class="box2">
    <h2><span><?php echo $v['course_name'] ?></span></h2>
    <h2>主讲人：<span><?php echo $v['teacher']['teacher_name'] ?></span>老师</h2>
    	<dl>
        	<dt><a href="#"><img src="/assets/image/xx.jpg" width="99" height="133" /></a></dt>
            <dd>
            <a href="#"><?php echo $v['teacher']['teacher_desc'] ?></a> </dd>
        </dl>
        <p>课程难度：<?php echo $v['rank']['rank_name'] ?> 教师来源：<?php echo $v['teacher']['teacher_from'] ?></p>
        <p>开设时间：<span>8月3日到9月30日每周五、六20点整</span></p>
        <p>招收人数：<span class="cheng">50</span>人 已报名人数：<span class="cheng"><?php echo $v['apply_num'] ?></span>人</p>
        <h4><a href="#">LEARN MORE</a> <span class="cheng">&gt;</span></h4>
    </div>
    <?php } ?>
  </div>
  <div class="main3">

    	<?php echo LinkPager::widget([
				'pagination' => $pagination,
				'firstPageLabel'=>"首页",
				'prevPageLabel'=>'上一页',
				'nextPageLabel'=>'下一页',
				'lastPageLabel'=>'尾页',
			]);?>

  </div>
</div>
<script type="text/javascript">
	$(document).ready(function(){

	});
</script>